<template>
	<view class="max-box">
		<view class="platform-customer">
			<view class="customer-title">平台客服</view>
			<view class="customer-content">
				<view class="content">
					<view class="content-box">
						<u-icon name="info-circle" size="28"></u-icon>
					</view>
					<view class="business-hours">
						<view class="hours">营业时间: 10-12</view>
						<view class="platform-phone">
							<text>平台电话:</text>
							<button class="call" @click="callPhone = true">拨打</button>
							<u-modal :show="callPhone" :title="title" :content='content' showCancelButton="取消"
								confirmText="呼叫" confirmColor="red" @confirm="call" @cancel="cancel"></u-modal>
						</view>
					</view>
				</view>
			</view>
		</view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				// 控制模态框显示隐藏
				callPhone: false,
				// 模态框的标题
				title: '标题',
				// 模态框的内容
				content: '即将打电话给'
			}
		},
		methods: {
			// 模态框呼叫按钮
			call(){
				this.callPhone = false
			},
			// 模态框取消按钮
			cancel(){
				this.callPhone = false
			}
		}
	}
</script>

<style lang="scss" scoped>
	.max-box {
		height: 1445rpx;
		background: linear-gradient(#FEAE65, #FA6B43, #F51B1B);
	}

	.platform-customer {
		padding: 40rpx 30rpx 20rpx 30rpx;
	}

	.customer-content {
		margin-top: 30rpx;
		height: 20rpx;
		background-color: rgb(190, 0, 14);
		border-radius: 40rpx;
		padding: 15rpx 20rpx 0rpx 20rpx;
	}

	.customer-title {
		text-align: center;
		color: #fff;
		font-size: 60rpx;
	}

	.content {
		background-color: #fff;
		padding: 40rpx 40rpx 30rpx 40rpx;
		display: flex;
		justify-content: center;
		flex-wrap: wrap;
	}

	.content-box {
		width: 450rpx;
		height: 450rpx;
		background-color: rgb(243, 244, 246);
		display: flex;
		justify-content: center;
		align-items: center;
	}

	.business-hours {
		margin-top: 10rpx;
	}

	.hours {
		margin-left: 20rpx;
	}

	.platform-phone {
		margin-top: 20rpx;
		display: flex;
		align-items: center;
	}

	button::after {
		border: none;
	}

	button {
		padding-left: 20rpx;
		padding-right: 20rpx;
		text-align: center;
		line-height: 1.35;
		overflow: hidden;
		height: 100%;
	}

	.call {
		margin-left: 40rpx;
		width: 120rpx;
		border-radius: 10rpx;
		border: 1px solid #ccc;
		color: #9A9A9A;
		// padding: ;
	}
</style>